<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1.0,user-scale=no">
<link href="../bootstrap331/css/bootstrap.min.css" rel="stylesheet" >
<style type="text/css">
	
</style>

</head>
<body>
	<div class="row" >
		<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12">
        	<table class="table table-hover table-striped" style="text-align:center" >
            	<thead>
                	<tr >
                    	<th style="text-align:center">编号</th>
                        <th style="text-align:center">商户名称</th>
                        <th style="text-align:center">详细地址</th>
                        <th style="text-align:center">联系电话</th>
                        <th style="text-align:center">操作</th>
                    </tr>
                </thead>
            	<tbody>
                <#list shops as shop>
                	<tr>
                    	<td>${shop.code!}</td>
                        <td>${shop.name!}</td>
                        <td>${shop.address!}</td>
                        <td>联系电话</td>
                        <td><button class="btn btn-xs btn-primary" onClick="return delete_shop();" >删除</button>&nbsp;
                        	<button class="btn btn-xs btn-primary"
                            	 data-toggle="modal" data-target="#myModal_${shop.code!}" >详情</button>&nbsp;
                            <button class="btn btn-xs btn-primary">修改</button>
                        </td>
                    </tr>
                    
                    <div class="modal"  id="myModal_${shop.code!}" tabindex="-1" role="dialog"  aria-hidden="true">
        				<div class="modal-dialog">
            				<div class="modal-content">
                				<div class="modal-header">
        							<button type="button" class="close" 
                                    data-dismiss="modal" aria-label="Close">
                                    <span aria-hidden="true">&times;</span></button>
        							<h4 class="modal-title" id="myModalLabel">Modal title</h4>
      							</div>
                                  <div class="modal-body">
                                   	${shop.code!}
                                    
                                  </div>
                                  <div class="modal-footer">
                                    <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
                                    <button type="button" class="btn btn-primary">Save changes</button>
                                  </div>
                
                            </div>
                        </div>
                    </div>
                
                </div>
               </#list> 	
                </tbody>
            </table>
        
        </div>
        
        
        




<script type="text/javascript" src="../js/jquery-1.9.1.js"></script>
<script type="text/javascript" src="../bootstrap331/js/bootstrap.min.js"></script>
<script type="text/javascript">
	function delete_shop(){
		var res=window.confirm("确定删除本商家？");
		if(res==true) alert("被删除了");
		else alert("最终没有删除！");
	}
	
	
</script>

</body>
</html>
